<?php
/**
 * unpor_share模块微站定义
 *
 * @author benhailong
 * @url 
 */

/**
 * 主要入口文件
 */

defined('IN_IA') or exit('Access Denied');
define('IA_ROOT', str_replace("\\", '/', dirname(__FILE__)));
require_once IA_ROOT . '/addons/unpor_baby/inc/function.php';
require_once IA_ROOT . '/addons/unpor_baby/common/openkit.php';
require_once IA_ROOT . '/addons/unpor_baby/common/defines.php';
include IA_ROOT . '/addons/unpor_baby/common/template.func.php';

class Unpor_babyModuleSite extends WeModuleSite {
    public function unporMenu(){
        global $_W,$_GPC;
        $menu = array(
            array(
                'title' => '仪表盘',
                'icon' => 'layui-icon layui-icon-engine',
                'url' => 'javascript:;',
                'active' => ($_GPC['do'] == 'main') ? 'layui-nav-itemed' : '',
                'erMenu' => array(
                    array(
                        'title' => '首页',
                        'icon' => 'icon icon-swipe-copy',
                        'url' => $this->createWebUrl('main',array('dodo'=>'home')),
                        'active' => ($_GPC['dodo'] == 'home') ? 'layui-this' : '',
                    )
                ),
            ),
            array(
                'title' => '会员管理',
                'icon' => 'layui-icon layui-icon-home',
                'url' => 'javascript:;',
                'active' => (startwith($_GPC['do'],'user') || $_GPC['go'] == 'user') ? 'layui-nav-itemed' : '',
                'erMenu' => array(
                    array(
                        'title' => '会员列表',
                        'url' => $this->createWebUrl('common/go',array('dodo'=>'member','go'=>'user','operate'=>'list')),
                        'active' => ($_GPC['dodo'] == 'member') ? 'layui-this' : '',
                    ),
                    array(
                        'title' => '会员等级',
                        'icon' => 'icon icon-swipe-copy',
                        'url' => $this->createWebUrl('common/go',array('dodo'=>'grade','go'=>'user','operate'=>'list')),
                        'active' => ($_GPC['dodo'] == 'grade') ? 'layui-this' : '',
                    ),
                ),
            ),
        );
        return $menu;
    }

}